package com.ruoyi.project.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.system.mapper.LaborSubcontractMapper;
import com.ruoyi.project.system.domain.LaborSubcontract;
import com.ruoyi.project.system.service.ILaborSubcontractService;

/**
 * 劳务分包Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-10-15
 */
@Service
public class LaborSubcontractServiceImpl implements ILaborSubcontractService 
{
    @Autowired
    private LaborSubcontractMapper laborSubcontractMapper;

    /**
     * 查询劳务分包
     * 
     * @param id 劳务分包主键
     * @return 劳务分包
     */
    @Override
    public LaborSubcontract selectLaborSubcontractById(Long id)
    {
        return laborSubcontractMapper.selectLaborSubcontractById(id);
    }

    /**
     * 查询劳务分包列表
     * 
     * @param laborSubcontract 劳务分包
     * @return 劳务分包
     */
    @Override
    public List<LaborSubcontract> selectLaborSubcontractList(LaborSubcontract laborSubcontract)
    {
        return laborSubcontractMapper.selectLaborSubcontractList(laborSubcontract);
    }

    /**
     * 新增劳务分包
     * 
     * @param laborSubcontract 劳务分包
     * @return 结果
     */
    @Override
    public int insertLaborSubcontract(LaborSubcontract laborSubcontract)
    {
        return laborSubcontractMapper.insertLaborSubcontract(laborSubcontract);
    }

    /**
     * 修改劳务分包
     * 
     * @param laborSubcontract 劳务分包
     * @return 结果
     */
    @Override
    public int updateLaborSubcontract(LaborSubcontract laborSubcontract)
    {
        return laborSubcontractMapper.updateLaborSubcontract(laborSubcontract);
    }

    /**
     * 批量删除劳务分包
     * 
     * @param ids 需要删除的劳务分包主键
     * @return 结果
     */
    @Override
    public int deleteLaborSubcontractByIds(Long[] ids)
    {
        return laborSubcontractMapper.deleteLaborSubcontractByIds(ids);
    }

    /**
     * 删除劳务分包信息
     * 
     * @param id 劳务分包主键
     * @return 结果
     */
    @Override
    public int deleteLaborSubcontractById(Long id)
    {
        return laborSubcontractMapper.deleteLaborSubcontractById(id);
    }
}
